<template>
 <div class="list">
    <el-breadcrumb separator="/" class="breadcrumb">
      <el-breadcrumb-item :to="{ path: '/' }">首页</el-breadcrumb-item>
      <el-breadcrumb-item>动态列表页</el-breadcrumb-item>
   </el-breadcrumb>
   <div class="content">
    <el-table :data="infoList" @row-click="handleTableRow" style="width: 100%" border>
    <el-table-column type="index" label="序号" width="80" />
    <el-table-column prop="title" label="标题" align="center " min-width="400" />
    <el-table-column prop="publishDatetime" label="发布时间" width="180" />
  </el-table>
   </div>
 </div>
</template>

<script>
import { listInformation } from '@/api/bid/information'
export default {
  name: "list",
  data() {
    return {
      infoList: [],
    }
  },

  created() {
    this.getList();
  },

   methods: {
    getList() {
      listInformation().then(res => {
        console.log(res)
        this.infoList = res.rows
      })
    },
    handleTableRow(row) {
      this.$router.push({path:'/info/detail?id='+row.id})
    },
  }
}

</script>

<style>
</style>
